package com.dingxin.ship_together_api.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
* Author: ctj
* Date: 2022-09-30
* Time: 17:14
*/

/**
    * 航线sku表
    */
@ApiModel(value="航线sku表")
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "ship_together.route_sku")
public class RouteSku implements Serializable {
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @ApiModelProperty(value="")
    private Long id;

    /**
     * 航线id
     */
    @TableField(value = "route_spu_id")
    @ApiModelProperty(value="航线spu_id")
    private Long routeSpuId;

    /**
     * 目的地id
     */
    @TableField(value = "destination_id")
    @ApiModelProperty(value="目的地id")
    private Long destinationId;

    /**
     * 时间id
     */
    @TableField(value = "time_id")
    @ApiModelProperty(value="时间id")
    private Long timeId;

    /**
     * 座位id
     */
    @TableField(value = "seat_id")
    @ApiModelProperty(value="座位id")
    private Long seatId;

    /**
     * 总价
     */
    @TableField(value = "amount")
    @ApiModelProperty(value="总价")
    private Long amount;

    /**
     * 库存/剩余座位
     */
    @TableField(value = "stock")
    @ApiModelProperty(value="库存")
    private Integer stock;

    /**
     * 删除
     */
    @TableField(value = "deleted")
    @ApiModelProperty(value="删除")
    @JsonIgnore
    private Boolean deleted;

    /**
     * 乐观锁
     */
    @TableField(value = "version")
    @ApiModelProperty(value="乐观锁")
    @Version
    @JsonIgnore
    private Integer version;

    /**
     * 创建人
     */
    @TableField(value = "create_by" ,fill = FieldFill.INSERT)
    @ApiModelProperty(value="创建人")
    @JsonIgnore
    private String createBy;

    /**
     * 创建时间
     */
    @TableField(value = "create_time",fill = FieldFill.INSERT)
    @ApiModelProperty(value="创建时间")
    @JsonIgnore
    private Date createTime;

    /**
     * 更新人
     */
    @TableField(value = "update_by",fill = FieldFill.UPDATE)
    @ApiModelProperty(value="更新人")
    @JsonIgnore
    private String updateBy;

    /**
     * 更新时间
     */
    @TableField(value = "update_time",fill = FieldFill.UPDATE)
    @ApiModelProperty(value="更新时间")
    @JsonIgnore
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public static final String COL_ID = "id";

    public static final String COL_ROUTE_SPU_ID = "route_spu_id";

    public static final String COL_FISH_ID = "fish_id";

    public static final String COL_DESTINATION_ID = "destination_id";

    public static final String COL_TIME_ID = "time_id";

    public static final String COL_SEAT_ID = "seat_id";

    public static final String COL_AMOUNT = "amount";

    public static final String COL_STOCK = "stock";

    public static final String COL_DELETED = "deleted";

    public static final String COL_VERSION = "version";

    public static final String COL_CREATE_BY = "create_by";

    public static final String COL_CREATE_TIME = "create_time";

    public static final String COL_UPDATE_BY = "update_by";

    public static final String COL_UPDATE_TIME = "update_time";
}